package io.zhifei.modules.sys.system.service;

import com.baomidou.mybatisplus.extension.service.IService;
import io.zhifei.common.utils.PageUtils;
import io.zhifei.common.utils.R;
import io.zhifei.modules.sys.system.entity.SysSchoolEntity;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

/**
 * @ClassNameSchoolService
 * @Description
 * @Author
 * @Date2020/11/16 16:57
 * @Version V1.0
 **/

public interface SysSchoolService extends IService<SysSchoolEntity> {
    /***
     * 获取列表
     * @param page
     * @param pageSize
     * @param name
     * @param startTuition
     * @param endTuition
     * @return
     */
    PageUtils getList(Integer page, Integer pageSize, String name, String startTuition, String endTuition,String type);

    /***
     * 新增院校
     * @param schoolEntity
     */
    void add(SysSchoolEntity schoolEntity, Long userId);

    /***
     * 修改院校
     * @param userId
     */
    void update(SysSchoolEntity schoolEntity, Long userId);

    void delete(String[] ids);

    /**
     * 导入院校信息
     * @param file
     * @return
     */
    R importSchool(MultipartFile file);

    /**
     * 下载院校信息模板
     * @param request
     * @param response
     */
    void uploadSchoolExcel(HttpServletRequest request, HttpServletResponse response) throws IOException;

    void deleteAll();
}
